Skip to content

feat: Hermes architecture, Agentic UI, and CLI optimizations - #1148

Closed
Fahremback wants to merge 1 commit into
CodebuffAI:mainfrom
Fahremback:feat/agentic-ui-and-hermes-optimizations
Closed

feat: Hermes architecture, Agentic UI, and CLI optimizations#1148
Fahremback wants to merge 1 commit into
CodebuffAI:mainfrom
Fahremback:feat/agentic-ui-and-hermes-optimizations

Conversation

@Fahremback

Copy link
Copy Markdown

This PR introduces a suite of architectural and UI improvements to Freebuff CLI, including the auto-accordion tracker, 10k output truncation limit for LLMs, strict node_modules omission on ripgrep, and auth error resistance.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 13a6ee1733

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +142 to +146
useEffect(() => {
if (canRestart) {
const timer = setTimeout(() => {
startSameChatSession()
}, 3000)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Require explicit input before rejoining sessions

When a Freebuff session has ended and the banner is visible, this effect calls startSameChatSession() after 3 seconds whenever canRestart is true. startSameChatSession re-POSTs via refreshFreebuffSession, so a user who is just reading the ended banner or intending to change models with Esc is silently put into a new session and can consume the next daily session/fallback choice without pressing Enter. Please keep rejoin behind the Enter/button path.

Useful? React with 👍 / 👎.

Comment thread cli/src/chat.tsx Outdated
Comment on lines +1662 to +1665
const missionPath = getMissionPath(getProjectRoot() ?? process.cwd())
if (fs.existsSync(missionPath)) {
setTimeout(() => {
onSubmitPrompt('continue', agentMode).catch(() => {})

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Check mission status before auto-continuing

This only checks that the mission file exists before submitting an automatic continue after renewal. completeMission and cancelMission leave the same file on disk, so completed or cancelled missions still trigger an unsolicited prompt in the new session even though routeUserPrompt only attaches mission context for status === 'active'. Load the mission and require an active status before submitting.

Useful? React with 👍 / 👎.

Comment thread cli/src/missions/mission-store.ts Outdated

Execute a missão inteira de forma autônoma. Pesquise de forma estreita, edite, valide e corrija até a evidência confirmar o resultado. Enquanto existir trabalho seguro e acionável, não encerre nem devolva apenas diagnóstico ou próximos passos. Use write_todos como checklist vivo e agrupe alterações antes de executar testes caros.

O estado persistente está em .freebuff/mission.json. **PROTOCOLO DE DOUBLE-CHECK OBRIGATÓRIO**: Antes de atualizar o status para "completed", você DEVE realizar uma auto-revisão crítica. Questione-se: "Eu realmente concluí tudo? O código foi testado? As evidências são reais ou são suposições?". Se houver qualquer falha ou falta de verificação real, CONTINUE TRABALHANDO. Nunca declare conclusão baseado em suposições.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Point mission prompts at the actual state file

createMission writes through getMissionPath, which stores .freebuff/mission-${safeBranch}.json, but the prompt tells the agent to update .freebuff/mission.json. On any branch, an agent following this instruction updates a different file, so loadMission and the tracker keep reading the original branch-scoped mission as active and never observe completion or blockage. Interpolate the same path returned by getMissionPath into the prompt.

Useful? React with 👍 / 👎.

@Fahremback
Fahremback force-pushed the feat/agentic-ui-and-hermes-optimizations branch from 13a6ee1 to e6bacf7 Compare August 29, 2026 00:47
@codebuff-team

Copy link
Copy Markdown
Contributor

There's real work buried in here — common/src/mcp/client-pool.ts with its timeout/dedup logic and tests is solid, and the auth.ts nullish schema fix for name/email (agents/auth.ts) is a reasonable defensive fix. Those two alone would be a clean, portable PR.

But everything else is bundled together and each piece needs its own review:

  • common/src/tools/params/tool/run-terminal-command.ts: silently drops MAX_TERMINAL_TIMEOUT_SECONDS from 600 to 180. That's a breaking behavior change for anyone relying on longer sync timeouts, and it's not explained or tested — it just rides along with the "prevent hangs" prompt text.
  • cli/scripts/build-binary.ts: hardcodes production URLs, a dummy PostHog key, and a dummy Stripe key directly into the CLI binary build. This bakes vendor/billing config into a non-billing package and looks like it belongs to a different concern entirely (and touches territory adjacent to excluded billing/build-tools paths).
  • agents/base3.ts and cli/src/commands/mcp.ts / mission.ts: hardcoded Portuguese strings mixed into an otherwise English system prompt and CLI output ("METAS E SUBMETAS", "Nenhum servidor MCP configurado", etc). This is inconsistent localization dropped into shared product surfaces without any indication it's intentional or reviewed.
  • agents/mcp-enabled.ts: wires in four new MCP server dependencies (filesystem, memory, sequential-thinking, puppeteer) via npx — that's adding vendor integrations unilaterally, not a bug fix.
  • The whole "mission" feature (mission-store.ts, mission-todos-tracker.tsx, auto-continuation hooks in chat.tsx/router.ts) is a large, un-requested autonomous-task system with execSync('git rev-parse ...') used just to name a status file — a new, sprawling feature bolted onto a PR titled as an optimization pass.
  • use-send-message.ts retry-on-error logic string-matches error messages and retries indefinitely every 3s with no backoff or cap — could loop forever on a persistent network issue.

As one PR this is unreviewable and unportable wholesale. Please split: (1) MCP pool + auth fix as a tight PR, (2) the mission/todos feature as its own proposal with rationale and no hardcoded language, (3) drop the build-binary.ts env hardcoding and the timeout reduction entirely unless justified separately.

@codebuff-team codebuff-team added bot:triaged Classified by the community triage bot pr:needs-work Right idea, not mergeable as written labels Aug 29, 2026
@Fahremback

Copy link
Copy Markdown
Author

Closing in favor of #1149 and #1150 as requested by codebuff-team to separate concerns, fix localizations, and add retry backoffs.

@Fahremback Fahremback closed this Aug 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bot:triaged Classified by the community triage bot pr:needs-work Right idea, not mergeable as written

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants